package com.disease.api.service.mapper;

import com.baomidou.dynamic.datasource.annotation.DS;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.disease.api.service.mapper.DeathReportInfoMapper;
import com.disease.api.service.entity.DeathReportInfo;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@DS("master")
public interface DeathReportInfoMapper extends BaseMapper<DeathReportInfo>{

    DeathReportInfo queryDeathReportInfoById(@Param("id") String id);

    DeathReportInfo queryDeathReportInfoBySerialNumber(@Param("serialNumber") String serialNumber);

    DeathReportInfo queryOne(DeathReportInfo deathReportInfo);

    List<DeathReportInfo> queryDeathReportInfo(DeathReportInfo deathReportInfo);

    List<DeathReportInfo> queryDeathReportInfoByStatus(List<String> Status);

    List<DeathReportInfo> findDeathReportInfoBySerialNumberList(List<String> serialNumber);

    List<DeathReportInfo> findDeathReportInfoByIdCardList(List<String> idCards);

    List<DeathReportInfo> findDeathReportInfoByDeathIdList(List<String> deathIds);

    List<DeathReportInfo> findDeathReportInfoBySerialNumberOrPatientIdOrIdCard(@Param("serialNumbers")List<String> serialNumber,@Param("patientIds")List< String> patientIds,@Param("idCards")List<String> idCards);

    List<DeathReportInfo> selectByQuery(DeathReportInfo deathReportInfo);

    List<DeathReportInfo> queryDeathCardList(DeathReportInfo deathReportInfo);

    void insertOne(DeathReportInfo deathReportInfo);

    void updateByPatientId(DeathReportInfo deathReportInfo);

    void updateByCardNo(DeathReportInfo deathReportInfo);

    void updateByIdCard(@Param("oldIdCard")String oldIdCard,@Param("newIdCard")String newIdCard);

    void updateByEntity(DeathReportInfo deathReportInfo);

}
